#ifndef __DMAT4_H__
#define __DMAT4_H__

#include "dvec4.h"

namespace libvec
{
  struct mat4;

  struct dmat4
  {
    dvec4 v1, v2, v3, v4;

    dmat4();
    dmat4(mat4 m);
    dmat4(double value);
    dmat4(double n11, double n12, double n13, double n14,
        double n21, double n22, double n23, double n24,
        double n31, double n32, double n33, double n34,
        double n41, double n42, double n43, double n44);
    dmat4(dvec4 v1, dvec4 v2, dvec4 v3, dvec4 v4);

    dvec4 &operator[](int index);

    dmat4 operator=(dmat4 m);

    bool operator==(dmat4 m);
    bool operator!=(dmat4 m);

    dmat4 &operator+();
    dmat4 &operator-();

    dmat4 operator+(dmat4 m);
    dmat4 operator+=(dmat4 m);
    dmat4 operator-(dmat4 m);
    dmat4 operator-=(dmat4 m);
    dvec4 operator*(dvec4 v);
    dmat4 operator*(dmat4 m);
    dmat4 operator*=(dmat4 m);
    dmat4 operator*(double scale);
    dmat4 operator*=(double scale);
    dmat4 operator/(double scale);
    dmat4 operator/=(double scale);
  };
}

#endif /* __DMAT4_H__ */
